<template>
  <div>
    <nav-layout :layout="layout"></nav-layout>
    <total-data v-if="layout.indexof === 0"></total-data>
    <user-data v-else-if="layout.indexof === 1"></user-data>
    <product-data v-else></product-data>
  </div>
</template>
<script>
import navLayout from "@/views/NavLayout";
import totalData from "./TotalData";
import userData from "./UserData";
import productData from "./ProductData";
export default {
  data() {
    return {
      layout: {
        nav: ["总表", "人员对照表", "产品对照表"],
        indexof: 0
      }
    };
  },
  components: {
    navLayout,
    totalData,
    userData,
    productData
  }
};
</script>